# -----------------------------------------------------------------------------
VOC_LABELS = ('aeroplane', 'bicycle', 'bird', 'boat', 'bottle', 
              'bus', 'car', 'cat', 'chair', 'cow', 
              'diningtable', 'dog', 'horse', 'motorbike', 'person', 
              'pottedplant', 'sheep', 'sofa', 'train', 'tvmonitor')

VOC_NUM_CLASSES = len(VOC_LABELS)

# -----------------------------------------------------------------------------
MSCOCO_LABELS = ()

MSCOCO_NUM_CLASSES = len(MSCOCO_LABELS)


def get_label_map(labels):
    if isinstance(labels, str):
        if labels == 'VOC':
            labels = VOC_LABELS
        elif labels == 'MSCOCO':
            labels = MSCOCO_LABELS
        else:
            raise ValueError("label string not supported")
    
    label_map = {k: v + 1 for v, k in enumerate(labels)}
    label_map['background'] = 0

    return labels, label_map
